Pensieve Header: Work on the "infinitesimal Alexander module"; continues 2008-09/AlexanderEulerSpaces.nb.

<< KnotTheory`

(#-> Alexander[#][t])& /@ AllKnots[{3,7}]

K=Knot[7,7];
pd = PD[K];
gc=GC @@ pd /. X[i_,j_,k_,l_] :> If[PositiveQ[X[i,j,k,l]],
Ar[l,i,+1], Ar[j,i,-1]
];
False&& (gc = GC[Ar[1,3, +1], Ar[4,2,-1]]);
n = 2 Length[gc];
gc

Conventions for red objects:
  1. Legs start just to the right of the index; RedAr[0,7] means a red arrow starting to the right of position 0 (that is, to the left of everything) and ending to the right of position 7).
  2. If two (red) indices are the same, the heads are to the right of the tails.
  3. RedW[] is the legless wheel object.
  3. RedY[i,j,k] means "red Y with tails are i and j and head at k".

range=Range[0,n];
AllRedObjects=Flatten[{
Outer[RedAr, range, range], Outer[RedY, range, range, range], RedW[]
}];
Short[AllRedObjects]

The relations associated with a red objects involve all the ways of "pulling one leg one unit to the left" :

RedAr[PushLeft[i_], j_] := RedAr[i-1, j] + If[i-1==j, - RedW[], 0];
RedAr[i_,PushLeft[j_]] := RedAr[i, j-1]  + If[i==j,  RedW[], 0];
RedY[PushLeft[i_], j_, k_] := RedY[i-1,j,k] +If[i-1==k, RedW[], 0];
RedY[i_,j_,PushLeft[k_]] := RedY[i,j,k-1]+If[i==k, -RedW[], 0]+ If[j==k, RedW[],0];
RelationsIn[gc_GC, red_] := ReplaceList[
red*(Times @@ Select[gc, (Intersection[List@@#, List@@red] =!= {})&]), {
(* Tails commute for RedAr: *)
RedAr[i_, j_]Ar[i_,_, _]*_. :> -red+RedAr[PushLeft[i], j],
(* Commuting a RedAr tail across an Ar head *)
RedAr[i_,j_]Ar[k_, i_, s_]*_. :> -red +RedAr[PushLeft[i], j]+(X^s-1) RedY[k,i,j],
(* Commuting the head of a RedAr with the tail of an Ar *)
RedAr[i_,j_]Ar[j_, k_, s_]*_. :> -red + RedAr[i,PushLeft[j]]+(X^s-1) RedY[j,i,k-1],
(* Commuting the head of a RedAr with the head of an Ar *)
RedAr[i_,k_]Ar[j_, k_, s_]*_. :> -red + RedAr[i,PushLeft[k]]-(X^s-1)RedY[j,i,k-1],
(* The anti-symmetry of RedY: *)
RedY[i_, j_, k_] * _. :> red + RedY[j,i,k],
(* Tails commute for RedY: *)
RedY[i_, j_, k_]Ar[i_,_, _]*_. :> -red+RedY[PushLeft[i], j, k],
(* Commuting a RedY tail across an Ar head *)
RedY[i_,j_,k_]Ar[l_, i_, s_]*_. :> -red +RedY[PushLeft[i],j,k]-(X^s-1) RedY[i,l,k],
(* Commuting a RedY head across an Ar tail *)
RedY[i_,j_,k_]Ar[k_,l_,s_]*_. :> -red+ RedY[i,j,PushLeft[k]]-(X^s-1) RedY[i,j,l-1],
(* Commuting a RedY head across an Ar head *)
RedY[i_,j_,l_]Ar[k_,l_,s_]*_. :> -red+ RedY[i,j,PushLeft[l]]+(X^s-1) RedY[i,j,l-1]
}
]

AllRedRelations = Flatten[RelationsIn[gc, #]& /@ AllRedObjects];
rule = Thread[Rule[AllRedObjects, IdentityMatrix[Length[AllRedObjects]]]];
Short[RedRules=Map[
(
p = First@Part[AllRedObjects, First@Position[#, 1, {1}]];
p -> p-(#.AllRedObjects)
)&,
DeleteCases[mat=Simplify[RowReduce[AllRedRelations /. rule]], {0...}]
]]

Simplify[RedRules[[Table[Random[Integer, {1,Length[RedRules]}], {10}]]]]

RedZ=Plus @@ gc /. Ar[i_, j_, s_] :> s*RedAr[i,j]

Simplify[RedZ /. RedRules]